﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace IOA.MES.DataAccess.VModel
{
    /// <summary>
    /// 分片任务
    /// </summary>
    public class VDistributeTask : BaseVModel
    {
        private string _workOrderNo = string.Empty;
        private string _codeFront = string.Empty;
        private string _codeEnd = string.Empty;
        private string _singleCode;
        private string _workshopCode;
        private string _workshopName;
        private string _cellColorCode;
        private string _cellColor;
        private string _cellBoxNo;

        #region Public Property

        ///<Summary>
        /// 车间代码
        ///</Summary>
        public string WorkshopCode
        {
            get { return string.IsNullOrWhiteSpace(_workshopCode) ? string.Empty : _workshopCode; }
            set { _workshopCode = value; }
        }

        ///<Summary>
        /// 车间名称
        ///</Summary>
        public string WorkshopName
        {
            get { return string.IsNullOrWhiteSpace(_workshopName) ? string.Empty : _workshopName; }
            set { _workshopName = value; }
        }

        ///<Summary>
        /// 工单号
        ///</Summary>
        public string WorkOrderNo
        {
            get { return string.IsNullOrWhiteSpace(_workOrderNo) ? string.Empty : _workOrderNo; }
            set { _workOrderNo = value; }
        }

        ///<Summary>
        /// 设备ID
        ///</Summary>
        public int MachineId { get; set; }

        ///<Summary>
        /// 分片类型
        ///</Summary>
        public Enum.DistributeType DistributeType { get; set; }

        ///<Summary>
        /// 单个条码
        ///</Summary>
        public string SingleCode
        {
            get { return string.IsNullOrWhiteSpace(_singleCode) ? string.Empty : _singleCode; }
            set { _singleCode = value; }
        }

        ///<Summary>
        /// 条码前端
        ///</Summary>
        public string CodeFront
        {
            get { return string.IsNullOrWhiteSpace(_codeFront) ? string.Empty : _codeFront; }
            set { _codeFront = value; }
        }

        ///<Summary>
        /// 条码后端
        ///</Summary>
        public string CodeEnd
        {
            get { return string.IsNullOrWhiteSpace(_codeEnd) ? string.Empty : _codeEnd; }
            set { _codeEnd = value; }
        }

        ///<Summary>
        /// 序号位数
        ///</Summary>
        public int? SerialNumCount { get; set; }

        ///<Summary>
        /// 起始序号
        ///</Summary>
        public int? StartNum { get; set; }

        ///<Summary>
        /// 截止序号
        ///</Summary>
        public int? EndNum { get; set; }

        ///<Summary>
        /// 条码数量
        ///</Summary>
        public int CodeCount { get; set; }

        ///<Summary>
        /// 电池片颜色代码
        ///</Summary>
        public string CellColorCode
        {
            get { return string.IsNullOrWhiteSpace(_cellColorCode) ? string.Empty : _cellColorCode; }
            set { _cellColorCode = value; }
        }

        ///<Summary>
        /// 电池片颜色
        ///</Summary>
        public string CellColor
        {
            get { return string.IsNullOrWhiteSpace(_cellColor) ? string.Empty : _cellColor; }
            set { _cellColor = value; }
        }

        ///<Summary>
        /// 电池片效率
        ///</Summary>
        public decimal CellEfficiency { get; set; }

        ///<Summary>
        /// 电池片面积
        ///</Summary>
        public decimal CellArea { get; set; }

        ///<Summary>
        /// 电池片箱号
        ///</Summary>
        public string CellBoxNo
        {
            get { return string.IsNullOrWhiteSpace(_cellBoxNo) ? string.Empty : _cellBoxNo; }
            set { _cellBoxNo = value; }
        }
        #endregion
    }
}
